package com.topisv.tms.rest.qimen.qmenum;
/**
 * 库存件类别
 *
 * @author Fisher
 * @version 1.0.0
 */
public enum InventoryType {
    ERROR("error", "CC"),//破损件
    NOT_ERROR("noterror", "ZP"),//完好件
    ;
    
    InventoryType(String type, String desc) {
        this.type = type;
        this.desc = desc;
    }

    private String type;
    private String desc;

    public String getType() {
        return type;
    }
    
    public String getDesc() {
        return desc;
    }
    
    public static String getOrderTypeDesc(String type){
        String typeDesc = null;
        for (InventoryType orderType : InventoryType.values()) {
            if (orderType.getType().equals(type)){
                typeDesc = orderType.getDesc();
                break;
            }
        }
        return typeDesc;
    }
    
}
